# Copyright (C) 2020-2025  CEA, EDF
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
#
# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#

from GeomAPI import *
from SketchAPI import *

from salome.shaper import model

model.begin()
partSet = model.moduleDocument()
Part_1 = model.addPart(partSet)
Part_1_doc = Part_1.document()
Sketch_1 = model.addSketch(Part_1_doc, model.standardPlane("XOY"))
SketchLine_1 = Sketch_1.addLine(0, 0, -200, 0)
SketchLine_1.setAuxiliary(True)
SketchProjection_1 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_1 = SketchProjection_1.createdFeature()
SketchConstraintCoincidence_1 = Sketch_1.setCoincident(SketchLine_1.startPoint(), SketchPoint_1.result())
SketchConstraintHorizontal_1 = Sketch_1.setHorizontal(SketchLine_1.result())
SketchLine_2 = Sketch_1.addLine(0, 0, 125.8640781685023, 155.4291923249108)
SketchLine_2.setAuxiliary(True)
SketchConstraintCoincidence_2 = Sketch_1.setCoincident(SketchLine_1.startPoint(), SketchLine_2.startPoint())
SketchProjection_2 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_3 = SketchProjection_2.createdFeature()
SketchConstraintAngle_1 = Sketch_1.setAngle(SketchLine_2.result(), SketchLine_3.result(), 51, type = "Direct")
SketchProjection_3 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_2 = SketchProjection_3.createdFeature()
SketchConstraintCoincidence_3 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_2).coordinates(), SketchLine_1.startPoint())
SketchProjection_4 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_3 = SketchProjection_4.createdFeature()
SketchConstraintCoincidence_4 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_3).coordinates(), SketchLine_1.startPoint())
SketchCircle_1 = Sketch_1.addCircle(-130, 0, 30)
SketchConstraintCoincidence_5 = Sketch_1.setCoincident(SketchLine_1.result(), SketchCircle_1.center())
SketchConstraintRadius_1 = Sketch_1.setRadius(SketchCircle_1.results()[1], 30)
SketchCircle_2 = Sketch_1.addCircle(-130, 0, 15)
SketchConstraintCoincidence_6 = Sketch_1.setCoincident(SketchCircle_1.center(), SketchCircle_2.center())
SketchConstraintRadius_2 = Sketch_1.setRadius(SketchCircle_2.results()[1], 15)
SketchConstraintCoincidence_7 = Sketch_1.setCoincident(SketchCircle_1.center(), SketchCircle_2.center())
SketchCircle_3 = Sketch_1.addCircle(0, 0, 22)
SketchConstraintCoincidence_8 = Sketch_1.setCoincident(SketchLine_1.startPoint(), SketchCircle_3.center())
SketchConstraintRadius_3 = Sketch_1.setRadius(SketchCircle_3.results()[1], 22)
SketchProjection_5 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_4 = SketchProjection_5.createdFeature()
SketchConstraintCoincidence_9 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_4).coordinates(), SketchLine_1.startPoint())
SketchCircle_4 = Sketch_1.addCircle(79.92368958823798, 98.69753716583253, 25)
SketchConstraintCoincidence_10 = Sketch_1.setCoincident(SketchLine_2.result(), SketchCircle_4.center())
SketchConstraintRadius_4 = Sketch_1.setRadius(SketchCircle_4.results()[1], 25)
SketchConstraintDistance_1 = Sketch_1.setDistance(SketchCircle_4.center(), SketchLine_1.startPoint(), 127, True)
SketchCircle_5 = Sketch_1.addCircle(79.92368958823798, 98.69753716583253, 10.5)
SketchConstraintCoincidence_11 = Sketch_1.setCoincident(SketchCircle_4.center(), SketchCircle_5.center())
SketchConstraintRadius_5 = Sketch_1.setRadius(SketchCircle_5.results()[1], 10.5)
SketchCircle_6 = Sketch_1.addCircle(-22, 0, 50)
SketchConstraintRadius_6 = Sketch_1.setRadius(SketchCircle_6.results()[1], 50)
SketchConstraintDistanceHorizontal_1 = Sketch_1.setHorizontalDistance(SketchCircle_1.center(), SketchLine_1.startPoint(), 130)
SketchConstraintCoincidence_12 = Sketch_1.setCoincident(SketchCircle_6.center(), SketchCircle_3.results()[1])
SketchLine_4 = Sketch_1.addLine(-135.5555553202231, -29.48110929195068, -31.25925965787122, -49.13518200422299)
SketchConstraintCoincidence_13 = Sketch_1.setCoincident(SketchLine_4.endPoint(), SketchCircle_6.results()[1])
SketchConstraintTangent_1 = Sketch_1.setTangent(SketchLine_4.result(), SketchCircle_6.results()[1])
SketchConstraintTangent_2 = Sketch_1.setTangent(SketchLine_4.result(), SketchCircle_1.results()[1])
SketchLine_5 = Sketch_1.addLine(100.207326266124, 84.08336295232411, 18.56727244892193, -29.22834935563313)
SketchLine_5.setName("SketchLine_7")
SketchLine_5.result().setName("SketchLine_7")
SketchConstraintCoincidence_14 = Sketch_1.setCoincident(SketchLine_5.startPoint(), SketchCircle_4.results()[1])
SketchConstraintCoincidence_15 = Sketch_1.setCoincident(SketchLine_5.endPoint(), SketchCircle_6.results()[1])
SketchConstraintTangent_3 = Sketch_1.setTangent(SketchLine_5.result(), SketchCircle_4.results()[1])
SketchProjection_6 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_5 = SketchProjection_6.createdFeature()
SketchConstraintCoincidence_16 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_5).coordinates(), SketchLine_1.startPoint())
SketchConstraintTangent_4 = Sketch_1.setTangent(SketchLine_5.result(), SketchCircle_6.results()[1])
SketchProjection_7 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_6 = SketchProjection_7.createdFeature()
SketchConstraintCoincidence_17 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_6).coordinates(), SketchLine_1.startPoint())
SketchConstraintLength_1 = Sketch_1.setLength(SketchLine_1.result(), 200)
SketchConstraintLength_2 = Sketch_1.setLength(SketchLine_2.result(), 200)
SketchProjection_8 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OY"), False)
SketchLine_6 = SketchProjection_8.createdFeature()
SketchLine_6.setName("SketchLine_9")
SketchLine_6.result().setName("SketchLine_9")
SketchLine_7 = Sketch_1.addLine(-58.90083370282744, 5.000000000000203, -28.28427124763085, 5.000000000033542)
SketchLine_7.setName("SketchLine_11")
SketchLine_7.result().setName("SketchLine_11")
SketchConstraintHorizontal_2 = Sketch_1.setHorizontal(SketchLine_7.result())
SketchArc_1 = Sketch_1.addArc(1.092525663159903, -2.072674848391145, -23.6595708565321, 8.099435269932149, 1.823223447996278, 24.67810433886826, True)
SketchArc_1.setName("SketchArc_2")
SketchArc_1.result().setName("SketchArc_2")
SketchArc_1.results()[1].setName("SketchArc_2_2")
SketchArc_2 = Sketch_1.addArc(-28.28427124755999, 10.00000000000959, -28.28427124763085, 5.000000000033542, -23.6595708565321, 8.099435269932149, False)
SketchArc_2.setName("SketchArc_3")
SketchArc_2.result().setName("SketchArc_3")
SketchArc_2.results()[1].setName("SketchArc_3_2")
SketchConstraintCoincidence_18 = Sketch_1.setCoincident(SketchLine_7.endPoint(), SketchArc_2.startPoint())
SketchConstraintCoincidence_19 = Sketch_1.setCoincident(SketchArc_1.startPoint(), SketchArc_2.endPoint())
SketchBSpline_1 = Sketch_1.addSpline(poles = [(5.42506581245492, 28.95281880404086), (8.251261958075688, 26.29329599041063), (7.364240199526506, 23.57679185485375), (1.82322344799795, 24.67810433886992)])
[SketchPoint_7, SketchPoint_8, SketchPoint_9, SketchPoint_10] = SketchBSpline_1.controlPoles(auxiliary = [0, 1, 2, 3])
[SketchLine_8, SketchLine_9, SketchLine_10] = SketchBSpline_1.controlPolygon(auxiliary = [0, 1, 2])
SketchConstraintCoincidence_20 = Sketch_1.setCoincident(SketchAPI_Point(SketchPoint_10).coordinates(), SketchArc_1.results()[1])
SketchConstraintCoincidence_21 = Sketch_1.setCoincident(SketchArc_1.startPoint(), SketchArc_2.results()[1])
SketchConstraintCoincidence_22 = Sketch_1.setCoincident(SketchLine_7.endPoint(), SketchArc_2.results()[1])
SketchConstraintTangent_5 = Sketch_1.setTangent(SketchLine_7.result(), SketchArc_2.results()[1])
SketchConstraintTangent_6 = Sketch_1.setTangent(SketchArc_2.results()[1], SketchArc_1.results()[1])
SketchArc_3 = Sketch_1.addArc(-59.53980728749703, 7.416963540217947, -62.03603251498611, 7.554293849432937, -58.90083370282744, 5.000000000000203, False)
SketchArc_3.setName("SketchArc_4")
SketchArc_3.result().setName("SketchArc_4")
SketchArc_3.results()[1].setName("SketchArc_4_2")
SketchConstraintCoincidence_23 = Sketch_1.setCoincident(SketchLine_7.startPoint(), SketchArc_3.endPoint())
SketchConstraintCoincidence_24 = Sketch_1.setCoincident(SketchArc_3.endPoint(), SketchLine_7.result())
SketchConstraintRadius_7 = Sketch_1.setRadius(SketchArc_3.results()[1], 2.5)
SketchConstraintRadius_8 = Sketch_1.setRadius(SketchArc_2.results()[1], 5)
SketchProjection_9 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_11 = SketchProjection_9.createdFeature()
SketchConstraintDistanceVertical_1 = Sketch_1.setVerticalDistance(SketchLine_7.endPoint(), SketchAPI_Point(SketchPoint_11).coordinates(), 5)
SketchProjection_10 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_12 = SketchProjection_10.createdFeature()
SketchProjection_11 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_13 = SketchProjection_11.createdFeature()
SketchConstraintRigid_1 = Sketch_1.setFixed(SketchBSpline_1.result())
SketchConstraintDistance_2 = Sketch_1.setDistance(SketchArc_2.center(), SketchLine_1.startPoint(), 30, True)
SketchConstraintDistance_3 = Sketch_1.setDistance(SketchArc_3.center(), SketchAPI_Point(SketchPoint_1).coordinates(), 60, True)
SketchProjection_12 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_11 = SketchProjection_12.createdFeature()
SketchLine_11.setName("SketchLine_13")
SketchLine_11.result().setName("SketchLine_13")
SketchProjection_13 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_12 = SketchProjection_13.createdFeature()
SketchLine_12.setName("SketchLine_15")
SketchLine_12.result().setName("SketchLine_15")
SketchProjection_14 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_13 = SketchProjection_14.createdFeature()
SketchLine_13.setName("SketchLine_16")
SketchLine_13.result().setName("SketchLine_16")
SketchConstraintDistance_4 = Sketch_1.setDistance(SketchArc_3.center(), SketchArc_2.center(), 31.3620887458, True)
SketchConstraintDistance_5 = Sketch_1.setDistance(SketchArc_1.center(), SketchAPI_Point(SketchPoint_1).coordinates(), 2.34298812456, True)
SketchConstraintCoincidence_25 = Sketch_1.setCoincident(SketchArc_1.results()[1], SketchArc_1.startPoint())
SketchConstraintCoincidence_26 = Sketch_1.setCoincident(SketchArc_2.results()[1], SketchLine_7.endPoint())
SketchConstraintCoincidence_27 = Sketch_1.setCoincident(SketchArc_1.endPoint(), SketchLine_10.result())
SketchConstraintCoincidence_28 = Sketch_1.setCoincident(SketchArc_3.startPoint(), SketchArc_3.results()[1])
SketchArc_4 = Sketch_1.addArc(-24.2523466963382, 5.475617146697203, 5.42506581245492, 28.95281880404086, -62.03603251498611, 7.554293849432937, False)
SketchArc_4.setName("SketchArc_5")
SketchArc_4.result().setName("SketchArc_5")
SketchArc_4.results()[1].setName("SketchArc_5_2")
SketchConstraintCoincidence_29 = Sketch_1.setCoincident(SketchBSpline_1.startPoint(), SketchArc_4.startPoint())
SketchConstraintCoincidence_30 = Sketch_1.setCoincident(SketchArc_3.startPoint(), SketchArc_4.endPoint())
SketchConstraintRadius_9 = Sketch_1.setRadius(SketchArc_4.results()[1], 37.8408220164)
SketchConstraintCoincidence_31 = Sketch_1.setCoincident(SketchArc_4.startPoint(), SketchBSpline_1.startPoint())
SketchConstraintCoincidence_32 = Sketch_1.setCoincident(SketchArc_4.startPoint(), SketchBSpline_1.startPoint())
SketchConstraintTangent_7 = Sketch_1.setTangent(SketchArc_4.results()[1], SketchArc_3.results()[1])
SketchProjection_15 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_14 = SketchProjection_15.createdFeature()
SketchLine_14.setName("SketchLine_17")
SketchLine_14.result().setName("SketchLine_17")
SketchConstraintMirror_1_objects = [SketchArc_1.results()[1], SketchArc_2.results()[1], SketchLine_7.result(), SketchArc_3.results()[1], SketchArc_4.results()[1]]
SketchConstraintMirror_1 = Sketch_1.addMirror(SketchLine_14.result(), SketchConstraintMirror_1_objects)
[SketchArc_5, SketchArc_6, SketchLine_15, SketchArc_7, SketchArc_8] = SketchConstraintMirror_1.mirrored()
SketchArc_8.setName("SketchArc_9")
SketchArc_8.result().setName("SketchArc_9")
SketchArc_8.results()[1].setName("SketchArc_9_2")
SketchArc_7.setName("SketchArc_8")
SketchArc_7.result().setName("SketchArc_8")
SketchArc_7.results()[1].setName("SketchArc_8_2")
SketchLine_15.setName("SketchLine_18")
SketchLine_15.result().setName("SketchLine_18")
SketchArc_6.setName("SketchArc_7")
SketchArc_6.result().setName("SketchArc_7")
SketchArc_6.results()[1].setName("SketchArc_7_2")
SketchArc_5.setName("SketchArc_6")
SketchArc_5.result().setName("SketchArc_6")
SketchArc_5.results()[1].setName("SketchArc_6_2")
SketchProjection_16 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_16 = SketchProjection_16.createdFeature()
SketchLine_16.setName("SketchLine_19")
SketchLine_16.result().setName("SketchLine_19")
SketchProjection_17 = Sketch_1.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchLine_17 = SketchProjection_17.createdFeature()
SketchLine_17.setName("SketchLine_20")
SketchLine_17.result().setName("SketchLine_20")
SketchCircle_7 = Sketch_1.addCircle(-15, -2.323482427062702e-11, 4)
SketchConstraintCoincidence_33 = Sketch_1.setCoincident(SketchLine_1.result(), SketchCircle_7.center())
SketchConstraintRadius_10 = Sketch_1.setRadius(SketchCircle_7.results()[1], 4)
SketchProjection_18 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_14 = SketchProjection_18.createdFeature()
SketchMultiRotation_1 = Sketch_1.addRotation([SketchCircle_7.results()[1]], SketchAPI_Point(SketchPoint_14).coordinates(), 360, 7, True)
[SketchCircle_8, SketchCircle_9, SketchCircle_10, SketchCircle_11, SketchCircle_12, SketchCircle_13] = SketchMultiRotation_1.rotated()
SketchProjection_19 = Sketch_1.addProjection(model.selection("VERTEX", "PartSet/Origin"), False)
SketchPoint_15 = SketchProjection_19.createdFeature()
SketchConstraintDistanceHorizontal_2 = Sketch_1.setHorizontalDistance(SketchCircle_7.center(), SketchAPI_Point(SketchPoint_15).coordinates(), 15)
SketchArc_9 = Sketch_1.addArc(1.920808383685174, -28.25067992433036, 1.823223447996874, -24.67810433889008, 5.425065812456392, -28.95281880404202, True)
SketchArc_9.setName("SketchArc_10")
SketchArc_9.result().setName("SketchArc_10")
SketchArc_9.results()[1].setName("SketchArc_10_2")
SketchConstraintCoincidence_34 = Sketch_1.setCoincident(SketchAPI_Arc(SketchArc_5).endPoint(), SketchArc_9.startPoint())
SketchConstraintCoincidence_35 = Sketch_1.setCoincident(SketchAPI_Arc(SketchArc_8).startPoint(), SketchArc_9.endPoint())
SketchConstraintCoincidence_36 = Sketch_1.setCoincident(SketchAPI_Arc(SketchArc_5).endPoint(), SketchArc_9.results()[1])
SketchConstraintCoincidence_37 = Sketch_1.setCoincident(SketchAPI_Arc(SketchArc_8).startPoint(), SketchArc_8.results()[1])
SketchConstraintTangent_8 = Sketch_1.setTangent(SketchArc_5.results()[1], SketchArc_9.results()[1])
SketchConstraintCoincidence_38 = Sketch_1.setCoincident(SketchLine_4.result(), SketchLine_4.endPoint())
SketchConstraintCoincidence_39 = Sketch_1.setCoincident(SketchLine_4.startPoint(), SketchCircle_1.results()[1])
SketchConstraintCoincidence_40 = Sketch_1.setCoincident(SketchCircle_6.center(), SketchLine_1.result())
SketchLine_18 = Sketch_1.addLine(-135.5313764125274, 29.48565541043907, -34.10055249047601, 48.51367466421663)
SketchLine_18.setName("SketchLine_28")
SketchLine_18.result().setName("SketchLine_28")
SketchConstraintCoincidence_41 = Sketch_1.setCoincident(SketchLine_18.startPoint(), SketchCircle_1.results()[1])
SketchLine_19 = Sketch_1.addLine(-34.10055249047601, 48.51367466421663, 65.46602437165166, 119.093024701899)
SketchLine_19.setName("SketchLine_31")
SketchLine_19.result().setName("SketchLine_31")
SketchConstraintCoincidence_42 = Sketch_1.setCoincident(SketchLine_18.endPoint(), SketchLine_19.startPoint())
SketchConstraintCoincidence_43 = Sketch_1.setCoincident(SketchLine_19.endPoint(), SketchCircle_4.results()[1])
SketchConstraintTangent_9 = Sketch_1.setTangent(SketchLine_19.result(), SketchCircle_4.results()[1])
SketchConstraintCoincidence_44 = Sketch_1.setCoincident(SketchLine_18.endPoint(), SketchCircle_6.results()[1])
SketchConstraintTangent_10 = Sketch_1.setTangent(SketchLine_18.result(), SketchCircle_1.results()[1])
SketchConstraintCoincidence_45 = Sketch_1.setCoincident(SketchLine_18.startPoint(), SketchCircle_1.results()[1])
SketchConstraintLength_3 = Sketch_1.setLength(SketchLine_18.result(), 103.200181968)
model.do()
Sketch_1.changeFacesOrder([[SketchCircle_1.results()[1], SketchCircle_1.results()[1], SketchCircle_1.results()[1], SketchCircle_2.results()[1]],
                           [SketchCircle_2.results()[1]],
                           [SketchCircle_3.results()[1], SketchCircle_7.results()[1], SketchCircle_8.results()[1], SketchCircle_9.results()[1], SketchCircle_10.results()[1], SketchCircle_11.results()[1], SketchCircle_12.results()[1], SketchCircle_13.results()[1]],
                           [SketchCircle_7.results()[1]],
                           [SketchCircle_4.results()[1], SketchCircle_4.results()[1], SketchCircle_4.results()[1], SketchCircle_5.results()[1]],
                           [SketchCircle_5.results()[1]],
                           [SketchCircle_6.results()[1], SketchCircle_6.results()[1], SketchCircle_6.results()[1], SketchCircle_6.results()[1], SketchCircle_3.results()[1], SketchArc_3.results()[1], SketchArc_4.results()[1], SketchBSpline_1.result(), SketchArc_1.results()[1], SketchArc_2.results()[1], SketchLine_7.result(), SketchArc_5.results()[1], SketchArc_9.results()[1], SketchArc_8.results()[1], SketchArc_7.results()[1], SketchLine_15.result(), SketchArc_6.results()[1]],
                           [SketchCircle_1.results()[1], SketchLine_4.result(), SketchCircle_6.results()[1], SketchLine_18.result(), SketchCircle_1.results()[1]],
                           [SketchCircle_9.results()[1]],
                           [SketchCircle_8.results()[1]],
                           [SketchCircle_10.results()[1]],
                           [SketchCircle_11.results()[1]],
                           [SketchCircle_12.results()[1]],
                           [SketchCircle_13.results()[1]],
                           [SketchArc_6.results()[1], SketchLine_15.result(), SketchArc_7.results()[1], SketchArc_8.results()[1], SketchArc_9.results()[1], SketchArc_5.results()[1]],
                           [SketchLine_7.result(), SketchArc_2.results()[1], SketchArc_1.results()[1], SketchBSpline_1.result(), SketchArc_4.results()[1], SketchArc_3.results()[1]],
                           [SketchLine_19.result(), SketchCircle_6.results()[1], SketchCircle_6.results()[1], SketchLine_5.result(), SketchCircle_4.results()[1]]
                          ])
model.do()
Sketch_2 = model.addSketch(Part_1_doc, model.defaultPlane("XOY"))
SketchLine_20 = Sketch_2.addLine(-108.2203399093874, 29.36510735335589, -63.72579508004998, 37.75878764820845)
SketchLine_20.setName("SketchLine_21")
SketchLine_20.result().setName("SketchLine_21")
SketchArc_10 = Sketch_2.addArc(-107.4788517859555, 25.43443296082969, -108.2203399093874, 29.36510735335589, -110.1251963597947, 22.43495436799721, False)
SketchArc_10.setName("SketchArc_11")
SketchArc_10.result().setName("SketchArc_11")
SketchArc_10.results()[1].setName("SketchArc_11_2")
SketchConstraintCoincidence_46 = Sketch_2.setCoincident(SketchLine_20.startPoint(), SketchArc_10.startPoint())
SketchProjection_20 = Sketch_2.addProjection(model.selection("EDGE", "Sketch_1/SketchCircle_1_2"), False)
SketchProjection_20.setName("SketchProjection_22")
SketchProjection_20.result().setName("SketchProjection_22")
SketchCircle_14 = SketchProjection_20.createdFeature()
SketchCircle_14.setName("SketchCircle_15")
SketchCircle_14.result().setName("SketchCircle_15")
SketchCircle_14.results()[1].setName("SketchCircle_15_2")
SketchArc_11 = Sketch_2.addArc(-129.9193971816675, -0.0007264653618642836, -110.1251963597947, 22.43495436799721, -100.0000021084595, -1.97639539394689e-07, True)
SketchArc_11.setName("SketchArc_12")
SketchArc_11.result().setName("SketchArc_12")
SketchArc_11.results()[1].setName("SketchArc_12_2")
SketchConstraintCoincidence_47 = Sketch_2.setCoincident(SketchArc_10.endPoint(), SketchArc_11.startPoint())
SketchConstraintTangent_11 = Sketch_2.setTangent(SketchCircle_14.results()[1], SketchArc_11.results()[1])
SketchArc_12 = Sketch_2.addArc(-63.07696996052059, 34.31945200772628, -63.72579508004998, 37.75878764820845, -60.38663142706861, 32.0806830976656, True)
SketchArc_12.setName("SketchArc_13")
SketchArc_12.result().setName("SketchArc_13")
SketchArc_12.results()[1].setName("SketchArc_13_2")
SketchConstraintCoincidence_48 = Sketch_2.setCoincident(SketchLine_20.endPoint(), SketchArc_12.startPoint())
SketchProjection_21 = Sketch_2.addProjection(model.selection("EDGE", "Sketch_1/SketchLine_1"), False)
SketchProjection_21.setName("SketchProjection_23")
SketchProjection_21.result().setName("SketchProjection_23")
SketchLine_21 = SketchProjection_21.createdFeature()
SketchLine_21.setName("SketchLine_23")
SketchLine_21.result().setName("SketchLine_23")
SketchProjection_22 = Sketch_2.addProjection(model.selection("EDGE", "Sketch_1/SketchCircle_6_2"), False)
SketchProjection_22.setName("SketchProjection_24")
SketchProjection_22.result().setName("SketchProjection_24")
SketchCircle_15 = SketchProjection_22.createdFeature()
SketchCircle_15.setName("SketchCircle_16")
SketchCircle_15.result().setName("SketchCircle_16")
SketchCircle_15.results()[1].setName("SketchCircle_16_2")
SketchArc_13 = Sketch_2.addArc(-21.7845712738051, -0.04223390990592879, -60.38663142706861, 32.0806830976656, -72.00408013001039, 1.63407197686378e-12, False)
SketchArc_13.setName("SketchArc_14")
SketchArc_13.result().setName("SketchArc_14")
SketchArc_13.results()[1].setName("SketchArc_14_2")
SketchConstraintCoincidence_49 = Sketch_2.setCoincident(SketchArc_12.endPoint(), SketchArc_13.startPoint())
SketchConstraintCoincidence_50 = Sketch_2.setCoincident(SketchLine_21.result(), SketchArc_13.endPoint())
SketchConstraintTangent_12 = Sketch_2.setTangent(SketchCircle_15.results()[1], SketchArc_13.results()[1])
SketchProjection_23 = Sketch_2.addProjection(model.selection("EDGE", "PartSet/OX"), False)
SketchProjection_23.setName("SketchProjection_25")
SketchProjection_23.result().setName("SketchProjection_25")
SketchLine_22 = SketchProjection_23.createdFeature()
SketchLine_22.setName("SketchLine_24")
SketchLine_22.result().setName("SketchLine_24")
SketchConstraintMirror_2_objects = [SketchArc_11.results()[1], SketchArc_10.results()[1], SketchLine_20.result(), SketchArc_12.results()[1], SketchArc_13.results()[1]]
SketchConstraintMirror_2 = Sketch_2.addMirror(SketchLine_22.result(), SketchConstraintMirror_2_objects)
[SketchArc_14, SketchArc_15, SketchLine_23, SketchArc_16, SketchArc_17] = SketchConstraintMirror_2.mirrored()
SketchArc_17.setName("SketchArc_18")
SketchArc_17.result().setName("SketchArc_18")
SketchArc_17.results()[1].setName("SketchArc_18_2")
SketchArc_16.setName("SketchArc_17")
SketchArc_16.result().setName("SketchArc_17")
SketchArc_16.results()[1].setName("SketchArc_17_2")
SketchLine_23.setName("SketchLine_25")
SketchLine_23.result().setName("SketchLine_25")
SketchArc_15.setName("SketchArc_16")
SketchArc_15.result().setName("SketchArc_16")
SketchArc_15.results()[1].setName("SketchArc_16_2")
SketchArc_14.setName("SketchArc_15")
SketchArc_14.result().setName("SketchArc_15")
SketchArc_14.results()[1].setName("SketchArc_15_2")
SketchConstraintTangent_13 = Sketch_2.setTangent(SketchLine_20.result(), SketchArc_12.results()[1])
SketchConstraintTangent_14 = Sketch_2.setTangent(SketchArc_12.results()[1], SketchArc_13.results()[1])
SketchConstraintCoincidence_51 = Sketch_2.setCoincident(SketchAPI_Arc(SketchArc_17).endPoint(), SketchArc_17.results()[1])
SketchConstraintTangent_15 = Sketch_2.setTangent(SketchLine_20.result(), SketchArc_10.results()[1])
SketchConstraintTangent_16 = Sketch_2.setTangent(SketchArc_10.results()[1], SketchArc_11.results()[1])
SketchConstraintCoincidence_52 = Sketch_2.setCoincident(SketchArc_10.startPoint(), SketchArc_10.results()[1])
SketchConstraintCoincidence_53 = Sketch_2.setCoincident(SketchArc_10.results()[1], SketchArc_11.startPoint())
SketchConstraintCoincidence_54 = Sketch_2.setCoincident(SketchLine_20.result(), SketchArc_12.startPoint())
SketchConstraintCoincidence_55 = Sketch_2.setCoincident(SketchArc_12.results()[1], SketchArc_13.startPoint())
SketchConstraintRadius_11 = Sketch_2.setRadius(SketchArc_12.results()[1], 3.5)
SketchConstraintRadius_12 = Sketch_2.setRadius(SketchArc_10.results()[1], 4)
SketchConstraintCoincidence_56 = Sketch_2.setCoincident(SketchArc_11.results()[1], SketchAPI_Arc(SketchArc_14).endPoint())
SketchConstraintLength_4 = Sketch_2.setLength(SketchLine_20.result(), 45.2793364297)
SketchConstraintCoincidence_57 = Sketch_2.setCoincident(SketchAPI_Arc(SketchArc_14).endPoint(), SketchArc_14.results()[1])
SketchConstraintCoincidence_58 = Sketch_2.setCoincident(SketchAPI_Arc(SketchArc_17).endPoint(), SketchArc_17.results()[1])
SketchConstraintCoincidence_59 = Sketch_2.setCoincident(SketchArc_13.startPoint(), SketchArc_12.results()[1])
SketchConstraintCoincidence_60 = Sketch_2.setCoincident(SketchArc_12.startPoint(), SketchArc_12.results()[1])
SketchConstraintCoincidence_61 = Sketch_2.setCoincident(SketchArc_12.results()[1], SketchArc_12.startPoint())
SketchConstraintDistance_6 = Sketch_2.setDistance(SketchArc_11.center(), SketchArc_11.startPoint(), 29.9193944029, True)
SketchConstraintDistance_7 = Sketch_2.setDistance(SketchArc_13.startPoint(), SketchArc_11.startPoint(), 50.6652250259, True)
SketchConstraintDistance_8 = Sketch_2.setDistance(SketchArc_11.center(), SketchArc_13.startPoint(), 76.5769047851, True)
SketchConstraintCoincidence_62 = Sketch_2.setCoincident(SketchArc_11.results()[1], SketchArc_11.startPoint())
SketchConstraintCoincidence_63 = Sketch_2.setCoincident(SketchArc_11.results()[1], SketchAPI_Arc(SketchArc_14).endPoint())
SketchConstraintCoincidence_64 = Sketch_2.setCoincident(SketchArc_11.results()[1], SketchAPI_Arc(SketchArc_14).endPoint())
SketchConstraintCoincidence_65 = Sketch_2.setCoincident(SketchAPI_Arc(SketchArc_14).endPoint(), SketchArc_14.results()[1])
SketchConstraintCoincidence_66 = Sketch_2.setCoincident(SketchArc_11.results()[1], SketchAPI_Arc(SketchArc_14).endPoint())
SketchConstraintCoincidence_67 = Sketch_2.setCoincident(SketchArc_11.endPoint(), SketchAPI_Arc(SketchArc_14).endPoint())
SketchLine_24 = Sketch_2.addLine(-7.203775711146425, 59.55358300428642, 47.2787789287226, 98.97639550686296)
SketchLine_24.setName("SketchLine_26")
SketchLine_24.result().setName("SketchLine_26")
SketchArc_18 = Sketch_2.addArc(50.55721779942619, 95.89389070242963, 47.2787789287226, 98.97639550686296, 55.03684890396159, 96.32156558298746, True)
SketchArc_18.setName("SketchArc_19")
SketchArc_18.result().setName("SketchArc_19")
SketchArc_18.results()[1].setName("SketchArc_19_2")
SketchConstraintCoincidence_68 = Sketch_2.setCoincident(SketchLine_24.endPoint(), SketchArc_18.startPoint())
SketchLine_25 = Sketch_2.addLine(39.0900005798679, 9.274871667252444, 80.48467495124737, 66.72930178826182)
SketchLine_25.setName("SketchLine_29")
SketchLine_25.result().setName("SketchLine_29")
SketchProjection_24 = Sketch_2.addProjection(model.selection("EDGE", "Sketch_1/SketchLine_7"), False)
SketchProjection_24.setName("SketchProjection_27")
SketchProjection_24.result().setName("SketchProjection_27")
SketchLine_26 = SketchProjection_24.createdFeature()
SketchLine_26.setName("SketchLine_30")
SketchLine_26.result().setName("SketchLine_30")
SketchConstraintParallel_1 = Sketch_2.setParallel(SketchLine_25.result(), SketchLine_26.result())
SketchConstraintParallel_1.setName("SketchConstraintParallel_3")
SketchArc_19 = Sketch_2.addArc(-22.21517834131148, -0.05169265751652471, -5.438628098470478, 47.2846200948962, 26.60573908050227, 11.72528265108334, True)
SketchArc_19.setName("SketchArc_23")
SketchArc_19.result().setName("SketchArc_23")
SketchArc_19.results()[1].setName("SketchArc_23_2")
SketchConstraintCoincidence_69 = Sketch_2.setCoincident(SketchCircle_15.results()[1], SketchArc_19.endPoint())
SketchConstraintTangent_17 = Sketch_2.setTangent(SketchCircle_15.results()[1], SketchArc_19.results()[1])
SketchConstraintTangent_17.setName("SketchConstraintTangent_20")
SketchArc_20 = Sketch_2.addArc(33.41054909313598, 13.3667937486244, 26.60573908050227, 11.72528265108334, 39.0900005798679, 9.274871667252444, False)
SketchArc_20.setName("SketchArc_24")
SketchArc_20.result().setName("SketchArc_24")
SketchArc_20.results()[1].setName("SketchArc_24_2")
SketchConstraintCoincidence_70 = Sketch_2.setCoincident(SketchArc_19.endPoint(), SketchArc_20.startPoint())
SketchConstraintCoincidence_71 = Sketch_2.setCoincident(SketchLine_25.startPoint(), SketchArc_20.endPoint())
SketchArc_21 = Sketch_2.addArc(-3.100260658330086, 53.88250160664763, -5.438628098470478, 47.2846200948962, -7.203775711146425, 59.55358300428642, True)
SketchArc_21.setName("SketchArc_27")
SketchArc_21.result().setName("SketchArc_27")
SketchArc_21.results()[1].setName("SketchArc_27_2")
SketchConstraintCoincidence_72 = Sketch_2.setCoincident(SketchArc_19.startPoint(), SketchArc_21.startPoint())
SketchConstraintCoincidence_73 = Sketch_2.setCoincident(SketchArc_21.results()[1], SketchArc_21.endPoint())
SketchConstraintCoincidence_74 = Sketch_2.setCoincident(SketchArc_21.results()[1], SketchArc_19.startPoint())
SketchConstraintCoincidence_75 = Sketch_2.setCoincident(SketchArc_20.endPoint(), SketchLine_25.result())
SketchProjection_25 = Sketch_2.addProjection(model.selection("EDGE", "Sketch_1/SketchCircle_4_2"), False)
SketchProjection_25.setName("SketchProjection_28")
SketchProjection_25.result().setName("SketchProjection_28")
SketchCircle_16 = SketchProjection_25.createdFeature()
SketchCircle_16.setName("SketchCircle_17")
SketchCircle_16.result().setName("SketchCircle_17")
SketchCircle_16.results()[1].setName("SketchCircle_17_2")
SketchArc_22 = Sketch_2.addArc(79.92369017333566, 98.69753728269234, 55.03684890396159, 96.32156558298746, 77.30496849970196, 73.83506738671026, False)
SketchArc_22.setName("SketchArc_22")
SketchArc_22.result().setName("SketchArc_22")
SketchArc_22.results()[1].setName("SketchArc_22_2")
SketchConstraintCoincidence_76 = Sketch_2.setCoincident(SketchCircle_16.results()[1], SketchArc_22.endPoint())
SketchConstraintTangent_18 = Sketch_2.setTangent(SketchCircle_16.results()[1], SketchArc_22.results()[1])
SketchConstraintCoincidence_77 = Sketch_2.setCoincident(SketchArc_22.startPoint(), SketchArc_18.endPoint())
SketchConstraintCoincidence_78 = Sketch_2.setCoincident(SketchArc_22.results()[1], SketchArc_22.startPoint())
SketchArc_23 = Sketch_2.addArc(76.83359861298372, 69.35982289158008, 77.30496849970196, 73.83506738671026, 80.48467495124737, 66.72930178826182, True)
SketchArc_23.setName("SketchArc_25")
SketchArc_23.result().setName("SketchArc_25")
SketchArc_23.results()[1].setName("SketchArc_25_2")
SketchConstraintCoincidence_79 = Sketch_2.setCoincident(SketchArc_22.endPoint(), SketchArc_23.startPoint())
SketchConstraintCoincidence_80 = Sketch_2.setCoincident(SketchLine_25.endPoint(), SketchArc_23.endPoint())
SketchConstraintCoincidence_81 = Sketch_2.setCoincident(SketchLine_25.endPoint(), SketchLine_25.result())
SketchConstraintCoincidence_82 = Sketch_2.setCoincident(SketchArc_18.results()[1], SketchLine_24.endPoint())
SketchConstraintRadius_13 = Sketch_2.setRadius(SketchArc_18.results()[1], 4.5)
SketchConstraintCoincidence_83 = Sketch_2.setCoincident(SketchArc_21.endPoint(), SketchLine_24.startPoint())
SketchConstraintRadius_14 = Sketch_2.setRadius(SketchArc_21.results()[1], 7)
SketchConstraintCoincidence_84 = Sketch_2.setCoincident(SketchArc_19.startPoint(), SketchArc_21.results()[1])
SketchConstraintCoincidence_85 = Sketch_2.setCoincident(SketchArc_19.startPoint(), SketchArc_19.results()[1])
SketchConstraintRadius_15 = Sketch_2.setRadius(SketchArc_20.results()[1], 7)
SketchConstraintRadius_16 = Sketch_2.setRadius(SketchArc_23.results()[1], 4.5)
SketchConstraintTangent_19 = Sketch_2.setTangent(SketchArc_18.results()[1], SketchArc_22.results()[1])
SketchConstraintTangent_20 = Sketch_2.setTangent(SketchArc_22.results()[1], SketchArc_23.results()[1])
SketchConstraintTangent_21 = Sketch_2.setTangent(SketchArc_23.results()[1], SketchLine_25.result())
SketchConstraintTangent_22 = Sketch_2.setTangent(SketchLine_25.result(), SketchArc_20.results()[1])
SketchConstraintTangent_23 = Sketch_2.setTangent(SketchArc_20.results()[1], SketchArc_19.results()[1])
SketchConstraintTangent_24 = Sketch_2.setTangent(SketchArc_19.results()[1], SketchArc_21.results()[1])
SketchConstraintTangent_25 = Sketch_2.setTangent(SketchArc_21.results()[1], SketchLine_24.result())
SketchConstraintDistance_9 = Sketch_2.setDistance(SketchArc_21.center(), SketchArc_23.center(), 81.41848269099999, True)
SketchConstraintDistance_10 = Sketch_2.setDistance(SketchArc_20.center(), SketchArc_18.center(), 84.2895603895, True)
SketchConstraintDistance_11 = Sketch_2.setDistance(SketchArc_22.center(), SketchArc_22.startPoint(), 25, True)
SketchConstraintDistance_12 = Sketch_2.setDistance(SketchLine_24.endPoint(), SketchLine_25.endPoint(), 46.287215906, True)
SketchConstraintDistance_13 = Sketch_2.setDistance(SketchArc_21.endPoint(), SketchArc_20.endPoint(), 68.34517084860001, True)
SketchConstraintCoincidence_86 = Sketch_2.setCoincident(SketchArc_15.results()[1], SketchAPI_Arc(SketchArc_15).endPoint())
SketchConstraintRadius_17 = Sketch_2.setRadius(SketchArc_13.results()[1], 50.2195265874)
SketchConstraintLength_5 = Sketch_2.setLength(SketchLine_24.result(), 67.2495866582)
model.do()
Sketch_2.changeFacesOrder([[SketchArc_21.results()[1], SketchArc_19.results()[1], SketchArc_20.results()[1], SketchLine_25.result(), SketchArc_23.results()[1], SketchArc_22.results()[1], SketchArc_18.results()[1], SketchLine_24.result()],
                           [SketchArc_10.results()[1], SketchArc_11.results()[1], SketchArc_14.results()[1], SketchArc_15.results()[1], SketchLine_23.result(), SketchArc_16.results()[1], SketchArc_17.results()[1], SketchArc_13.results()[1], SketchArc_12.results()[1], SketchLine_20.result()]
                          ])
model.do()
Extrusion_1 = model.addExtrusion(Part_1_doc, [model.selection("FACE", "Sketch_1/Face-SketchCircle_1_2f-SketchCircle_1_2f-SketchCircle_1_2f-SketchCircle_2_2r"), model.selection("FACE", "Sketch_1/Face-SketchCircle_6_2f-SketchCircle_6_2f-SketchCircle_6_2f-SketchCircle_6_2f-SketchCircle_3_2r-SketchArc_4_2r-SketchArc_5_2r-SketchBSpline_1f-SketchArc_2_2f-SketchArc_3_2r-SketchLine_11r-SketchArc_6_2f-SketchArc_10_2r-SketchArc_9_2r-SketchArc_8_2r-SketchLine_18f-SketchArc_7_2r")], model.selection(), 41, 0)
Extrusion_2 = model.addExtrusion(Part_1_doc, [model.selection("FACE", "Sketch_1/Face-SketchCircle_1_2r-SketchLine_4f-SketchCircle_6_2r-SketchLine_28r-SketchCircle_1_2r"), model.selection("FACE", "Sketch_1/Face-SketchLine_31r-SketchCircle_6_2r-SketchCircle_6_2r-SketchLine_7r-SketchCircle_4_2r")], model.selection(), 20, 0)
Extrusion_3 = model.addExtrusion(Part_1_doc, [model.selection("COMPOUND", "all-in-Sketch_2")], model.selection(), 50, -15)

model.testNbResults(Extrusion_3, 2)
model.testNbSubResults(Extrusion_3, [0, 0])
model.testNbSubShapes(Extrusion_3, GeomAPI_Shape.SOLID, [1, 1])
model.testNbSubShapes(Extrusion_3, GeomAPI_Shape.FACE, [10, 12])
model.testNbSubShapes(Extrusion_3, GeomAPI_Shape.EDGE, [48, 60])
model.testNbSubShapes(Extrusion_3, GeomAPI_Shape.VERTEX, [96, 120])
model.testResultsVolumes(Extrusion_3, [148061.943741445, 88885.950576849])

Extrusion_4 = model.addExtrusion(Part_1_doc, [model.selection("FACE", "Sketch_1/Face-SketchCircle_3_2f-SketchCircle_7_2r-SketchCircle_8_2r-SketchCircle_9_2r-SketchCircle_10_2r-SketchCircle_11_2r-SketchCircle_12_2r-SketchCircle_13_2r")], model.selection(), 36, 0)
Extrusion_5 = model.addExtrusion(Part_1_doc, [model.selection("FACE", "Sketch_1/Face-SketchCircle_4_2f-SketchCircle_4_2f-SketchCircle_4_2f-SketchCircle_5_2r")], model.selection(), 20, 0)
Extrusion_5.result().setColor(162, 177, 85)
Translation_1 = model.addTranslation(Part_1_doc, [model.selection("SOLID", "Extrusion_1_1")], axis = model.selection("EDGE", "PartSet/OZ"), distance = -12.5, keepSubResults = True)
Translation_1.result().setColor(162, 177, 85)
Cut_1 = model.addCut(Part_1_doc, [model.selection("SOLID", "Extrusion_2_1"), model.selection("SOLID", "Extrusion_2_2")], [model.selection("SOLID", "Extrusion_3_2"), model.selection("SOLID", "Extrusion_3_1")], keepSubResults = True)
Translation_2 = model.addTranslation(Part_1_doc, [model.selection("SOLID", "Extrusion_1_2"), model.selection("SOLID", "Extrusion_4_1")], axis = model.selection("EDGE", "PartSet/OZ"), distance = -10, keepSubResults = True)
Translation_2.result().setColor(162, 177, 85)
Translation_2.results()[1].setColor(162, 177, 85)

model.end()

model.testNbResults(Translation_2, 2)
model.testNbSubResults(Translation_2, [0, 0])
model.testNbSubShapes(Translation_2, GeomAPI_Shape.SOLID, [1, 1])
model.testNbSubShapes(Translation_2, GeomAPI_Shape.FACE, [19, 10])
model.testNbSubShapes(Translation_2, GeomAPI_Shape.EDGE, [102, 48])
model.testNbSubShapes(Translation_2, GeomAPI_Shape.VERTEX, [204, 96])
model.testResultsVolumes(Translation_2, [121260.8894199435, 42072.20881687451])

# TODO: study is not stable on dump.
# assert(model.checkPythonDump())
